<template>
  <label>
    {{$slots}}
  </label>
</template>

<script>
// 是否是合理的长度单位(数字,px,em)
const reg = /^\d+.?\d+(em|px)$/
export default {
  name: 'ZLabel',
  props:{
    'min-width': {
      required: false,
      type: [Number, String],
      validator(value){
        return reg.test(value)
      },
      default: '80px'
    }
  }
}
</script>

<style lang="scss" scoped>
</style>
